<#include "/common/head.ftl">

<#macro formatOn offering>
	<#if report.newOfferings.contains(offering)>
		;background-color:#B3F5DE
	<#elseif report.endOfferings.contains(offering)>
		;background-color:yellow
	</#if>
</#macro>

<html>

<head>
<title>Report for No. Students ${report.month}/${report.year}</title>

<style>
table {
	empty-cells:show;
	border-top: 1px solid black;
	border-right: 1px solid black;
}

table tr {
	
}

table tr td {
	border-left: 1px solid black;
	border-bottom: 1px solid black;
}
</style>

</head>

<body style="padding:0cm">

<div style="width:29.5cm;text-align:left;margin:0cm;padding:0px">

<h2 style="text-align:center;padding-top:0cm;margin:0cm">REPORT FOR ${i18n.getMessage('month.long.' + report.month)?upper_case} ${report.year}</h2>

<table border="0" style="width:28cm;margin-left:0cm;padding:0cm" cellspacing="0" cellpadding=0">
	<tr style="text-align:center;font-weight:bold">
		<td style="background-color:F0FFF0">&nbsp</td>
		<td style="background-color:F0FFF0">No. Classes</td>
		<td style="background-color:F0FFF0">Date</td>
		<td style="background-color:F0FFF0">No. Students</td>
		<td style="background-color:F0FFF0">No. SGT Members</td>
		<td style="background-color:F0FFF0">No. Placement Tests</td>
		<td style="background-color:F0FFF0">No. Make-Up Tests</td>
		<td style="background-color:F0FFF0">No. End Classes</td>
		<td style="background-color:F0FFF0">No. New Classes</td>
	</tr>
	<#list report.classifiedOfferings as offering>
		<tr>
			<td></td>
			<td style="width:3cm;border-right:0cm<@formatOn offering/>">${offering.name}</td>
			<td style="width:2.5cm;text-align:center<@formatOn offering/>">${(offering.startDate?string(i18n.getMessage('format.shortDate')))!}-${(offering.endDate?string(i18n.getMessage('format.shortDate')))!}</td>
			<td style="width:2.5cm;text-align:center"><#if offering.numberOfStudents!=0>${offering.numberOfStudents}<#else>&nbsp</#if></td>
			<#assign sgtMembers = report.getNumberOfSGTMembers(offering)>
			<td style="width:2.5cm;text-align:center"><#if sgtMembers!=0>${sgtMembers}<#else>&nbsp</#if></td>
			<td style="width:2cm;text-align:center">&nbsp</td>
			<td style="width:2cm;text-align:center">&nbsp</td>
			<td>&nbsp</td>
			<td>&nbsp</td>
		</tr>
	</#list>
	<tr>
		<td style="font-weight:bold;border-top:2px black solid">Total</td>
		<td style="border-top:2px black solid;text-align:center;font-weight:bold">${report.numberOfOfferings}</td>
		<td style="border-top:2px black solid;text-align:center;font-weight:bold">&nbsp</td>
		<td style="border-top:2px black solid;text-align:center;font-weight:bold">${report.numberOfStudents}</td>
		<td style="border-top:2px black solid;text-align:center;font-weight:bold">${report.numberOfSGTMembers}</td>
		<td style="border-top:2px black solid">&nbsp</td>
		<td style="border-top:2px black solid">&nbsp</td>
		<td style="border-top:2px black solid">&nbsp</td>
		<td style="border-top:2px black solid">&nbsp</td>
	</tr>
	<tr>
		<td style="font-weight:bold">Actuality</td>
		<td style="text-align:center;font-weight:bold">${report.numberOfActualOfferings}</td>
		<td>&nbsp</td>
		<td style="text-align:center;font-weight:bold">${report.numberOfActualStudents}</td>
		<td style="text-align:center;font-weight:bold">${report.numberOfActualSGTMembers}</td>
		<td style="text-align:center;font-weight:bold">${report.numberOfPlacementTests}</td>
		<td style="text-align:center;font-weight:bold">${report.numberOfMakeUpTests}</td>
		<td style="text-align:center;font-weight:bold">${report.numberOfEndOfferings}</td>
		<td style="text-align:center;font-weight:bold">${report.numberOfNewOfferings}</td>
	</tr>
</table>

<br/>

<table>
	<tr>
		<td style="width:2cm;background-color:yellow">&nbsp;</td>
		<td>END CLASSES</td>
	</tr>
	<tr>
		<td style="background-color:#B3F5DE">&nbsp;</td>
		<td>NEW CLASSES</td>
	</tr>
</table>

</div>

</body>
</html>